home *** CD-ROM | disk | FTP | other *** search
/ 3D World 113 / 3DW_113.iso / pc / Menu / Scenes / home.dir / Internal_60_Gallery Generate.ls < prev    next >
Encoding:
Text File  |  2008-09-12  |  1.0 KB  |  32 lines

  1. global gMenuList, gFullPath, SectionNumber, SectionPath, finalChan
  2.  
  3. on exitFrame me
  4.   member("SectionTitle").text = "GALLERY"
  5.   p = gMenuList[SectionNumber]
  6.   SectionPath = p.ItemPath
  7.   li = p.ItemList
  8.   lH = 20
  9.   lV = 100
  10.   offs = 20
  11.   myTitle = "GALLERY"
  12.   pLine = 1
  13.   repeat with i = 1 to the number of castMembers of castLib "SubItems"
  14.     if member(i, "subItems").name contains myTitle then
  15.       channel(finalChan + pLine).removeScriptedSprite()
  16.       channel(finalChan + pLine).makeScriptedSprite(member(i, "subItems"), point(lH, lV))
  17.       sprite(finalChan + pLine).scriptInstanceList = []
  18.       add(sprite(finalChan + pLine).scriptInstanceList, new(script("gallery_button"), 1))
  19.       _movie.sendSprite(finalChan + pLine, #Initialize, finalChan + pLine, pLine)
  20.       sprite(finalChan + pLine).ink = 36
  21.       lV = lV + 20
  22.       if pLine = 1 then
  23.         pSp = finalChan + pLine
  24.         pnum = pLine
  25.       end if
  26.       pLine = pLine + 1
  27.     end if
  28.   end repeat
  29.   aPath = gMenuList[SectionNumber].ItemList[pnum].ItemPath
  30.   sendSprite(pSp, #GenerateGallery, aPath)
  31. end
  32.